import java.util.Random;

public class StringUtil{

	/**
	 * @author huangzd
	 * @version 2015年6月3日下午3:02:10
	 * @describe 生成随机字符串
	 */
	public static String getRandomStr(int maxLength) {
		String base = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
		Random random = new Random();
		StringBuilder sb = new StringBuilder();
		for (int i = 0; i < maxLength; i++) {
			int number = random.nextInt(base.length());
			sb.append(base.charAt(number));
		}
		return sb.toString();
	}

}
